/*//搜索框点击事件
var search = document.querySelector(".search-toggle");
var content = document.querySelector(".search-box");
var lang = 'zh';


search.addEventListener('click',function () {

    if (lang=='zh'){
        content.style.display = "block";
        lang = 'en';
    }else{
        content.style.display = "none";
        lang = 'zh'
    }
});*/




//第一个swiper轮播
var swiper = new Swiper('.swiper-container', {
    slidesPerView: 3,
    spaceBetween: 30,
    slidesPerGroup: 3,
    loop: true,
    loopFillGroupWithBlank: true,
    pagination: {
        el: '.swiper-pagination',
        clickable: true,
    },
    navigation: {
        nextEl: '.swiper-button-next',
        prevEl: '.swiper-button-prev',
    },
});


//第二个swiper轮播
var swiper = new Swiper('.swiper-container', {
    slidesPerView: 3,
    spaceBetween: 30,
    pagination: {
        el: '.swiper-pagination',
        clickable: true,
    },
});


//回到顶部
var t = document.querySelector("#fh");
window.onscroll = function () {
    if (document.documentElement.scrollTop > 700){
        t.style.display = "block";
    }else {
        t.style.display = "none";
    }
};
t.addEventListener('click',function () {
    window.scrollTo({
        top:0,
        behavior:'smooth'
    })
});
